---
keywords:
- Smart Contracts
- deposit
- transfer
- chain
- Rust
- Solo
description: The `deposit` entrypoint credits the transferred IOTAS into your on-chain account.
image: /img/logo/WASP_logo_dark.png
---

import Tabs from "@theme/Tabs"
import TabItem from "@theme/TabItem"

# How to Deposit to a Chain

The `deposit` entrypoint credits the transferred IOTAS into your on-chain account.

<Tabs
    defaultValue="solo"
    values={[
        {label: 'Solo', value: 'solo'},
        {label: 'Solo (Schema)', value: 'soloctx'},
        {label: 'Rust (Schema)', value: 'rust'},
        {label: 'Go (Schema)', value: 'go'},
    ]}>
<TabItem value="solo">

```go
// deposits N iotas from wallet into chain
req := solo.NewCallParams(accounts.Contract.Name, accounts.FuncDeposit.Name)
_, err := chain.PostRequestSync(req.WithIotas(N), wallet)
require.NoError(t, err)
```

</TabItem>
<TabItem value="soloctx">

```go
// deposits N iotas from wallet into chain *chainID*
d := coreaccounts.ScFuncs.Deposit(ctx.Sign(wallet))
d.Func.TransferIotas(N).PostToChain(chainID)
require.NoError(t, ctx.Err)
```

</TabItem>
<TabItem value="rust">

```rust
// deposits N iotas from current SC into chain *chainID*
let d = coreaccounts::ScFuncs::deposit(ctx);
d.func.transfer_iotas(N).post_to_chain(chainID);
```

</TabItem>
<TabItem value="go">

```go
// deposits N iotas from current SC into chain *chainID*
d := coreaccounts.ScFuncs.Deposit(ctx)
d.Func.TransferIotas(N).PostToChain(chainID)
```

</TabItem>
</Tabs>
